Skip to content

Latest commit

 

History

History
104 lines (55 loc) · 5.34 KB

MaterialsAndSelections.md

File metadata and controls

104 lines (55 loc) · 5.34 KB

Go to Main Menu

Materials And Selections

Materials and Selections have already been defined in the previous Planning Documents section. In this section, we will talk about how to configure their behavior inside of the UE app.

First, let us quickly go over a very important term that will be constantly used throughout this Documentation: Data Assets.

Data Assets

Data Assets are how we store data inside of UE. The cool thing about them is that we can define completely how the Configurator behaves by just changing Data Assets, without touching a single line of code. Setting up the app requires you do the following simple steps:

  1. Import all 3D models
  2. Set up the scene with the 3D models
  3. Set up Cameras inside the scene
  4. Tag all Meshes and Cameras
  5. Configure the appropriate Data Assets

We will take a look at the last point and see how to create and configure Data Assets inside of Unreal Engine 5. So, how can I create a new Data Asset?

First, open the ContentDrawer using Ctrl + Space (or by clicking the tab at the bottom of the screen):

Then, navigate the menu to get to the folder where you want to create a new Data Asset:

Press Right Click on the Mouse and select Miscellaneous\DataAsset from the menu:

Select which type of Data Asset you want to create:

Name your newly created Data Asset properly:

Double click on the Data Asset to open it:

You're now ready to configure your new Data Asset!


Now, we will go through some very special DataAssets that we can use to determine how Materials and Selections will work in the app:

DataAssets for Materials

You will find these Data Assets in Content\Kambio\DataAssets\Materials:

We'll go through each one to know what they contain:

DA_MaterialIdToColor

This Data Asset maps Material Ids (see Planning Documents) to a string that represents their Color. These Colors are human-readable strings and are used in the UI.

DA_MaterialIdToType

This Data Asset maps Material Ids (see Planning Documents) to a string that represents their Material Type. A Material Type is simply what the Material is made of. It could be wood, cement, steel, brick, etc. These Material Types are human-readable strings and are used in the UI.

DA_MaterialIdToMaterialInstance

This Data Asset maps Material Ids (see Planning Documents) to Unreal Engine's Material Instances. A Material Instance is a type of asset that you can place on static meshes to apply a look and feel to them. These Material Instances are the ones being used by the user to configure their home.

DA_MaterialIdToUIMaterial

This Data Asset maps Material Ids (see Planning Documents) to a special type of Material Instance that can be applied to UI objects. The idea is to create a Material that looks as similar as possible to the one being applied to Meshes, but that is simplified enough to look good on UI.


DataAssets for Selections

You will find these Data Assets in Content\Kambio\DataAssets\Selections:

DA_SelectionIdToName

This Data Asset maps Selection Ids (see Planning Documents) to a human-readable string that is used to represent the type of selection in the UI.

DA_SelectionIdToVisibility

This Data Asset maps Selection Ids (see Planning Documents) to the Visibility of the Meshes that have been paired up with that Selection Id. Visibility is the way the app shows to the user if an object is being included or not in the final design.


Now that you know everything about DataAssets related to Materials and Selections, you can either go back to the Main Menu or read about Importing and Tagging 3D Models.